//\file: Sphere.h

#ifndef __ATOMTRACE_TRAX_SPHERE_H_
#define __ATOMTRACE_TRAX_SPHERE_H_

#include"Vector3.h"
#include"Ray.h"
#include "HitRecord.h"

namespace AtomTrace{

    class Sphere
    {
        public:
        Vector3 _center;
        float _radius;

        int _matID; // material ID
        int _objID; // object ID

        Sphere();
        Sphere(const Vector3 & iCenter, float iRadius);

        void Set(float cx, float cy, float cz, float iradius);
        void Set(const Vector3 & icenter, float iradius);

        bool Intersect(const Ray & iRay, HitRecord & hRec);
    };

}// AtomTrace

#endif //__ATOMTRACE_TRAX_SPHERE_H_
